package com.emily.test.service;

import com.emily.test.model.TResource;

import java.util.List;
import java.util.Map;

public interface
TResourceService {

    TResource selectByPrimaryKey(int id);

    int insertTResource(TResource tResource) throws Exception;

    int updateAllTResourceInfo(TResource resource) throws Exception;

    int updateSomeTResourceInfo(TResource resource) throws Exception;

    int deleteTResource(int id) throws Exception;

    List<TResource> getResourceList() throws Exception;

    int updateByPrimaryKeySelective(TResource tResource);
    /**
     * 根据角色ID查询资源信息列表
     * @param roleIds 角色ID，格式为:{1,2,3,4}
     * @return
     */
    List<Map<String,Object>> selectTReSourceInfoListByRoleIds(List roleIds);
    /**
     * 根据用户ID首页资源信息列表
     * @param  id 公司ID
     * @author zc
     * @return
     */
    List<Map<String,Object>> getIndexList(int id)throws Exception;

    /**
     * 根据资源条件查询符合条件的资源信息列表
     * @param tResource
     * @return
     */
    List<TResource> selectResourceListByCondition(TResource tResource);

    /**
     * 批量修改资源信息
     * @param resourceList
     * @return
     */
    int updateResourceInfoByIds(List<TResource> resourceList);

    List<Map<String, Object>> selectTReSourceInfoListByRoleIdIns(List list, String rName);
}
